package webEquipeRechercheGwt.client.entityMirror;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.Collection;


@SuppressWarnings("serial")
public class SoftwareMirror implements Serializable {

	private int id;
	private String website;
	private String title;
	private String description;
	private Collection<PersonMirror> developers;
	
	public SoftwareMirror() {
		super();
		developers = new ArrayList<PersonMirror>();
	}
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}
	public String getWebsite() {
		return website;
	}
	public void setWebsite(String website) {
		this.website = website;
	}
	public String getTitle() {
		return title;
	}
	public void setTitle(String title) {
		this.title = title;
	}
	public String getDescription() {
		return description;
	}
	public void setDescription(String description) {
		this.description = description;
	}
	public Collection<PersonMirror> getDevelopers() {
		return developers;
	}
	public void setDevelopers(Collection<PersonMirror> developers) {
		this.developers = developers;
	}
	public boolean equals(SoftwareMirror p){
		return p.getId()==getId();
	}
	
	@Override
	public boolean equals(Object p){
		try{
			SoftwareMirror param = (SoftwareMirror) p;
			return param.getId()==getId();
		}
		catch(ClassCastException e){
			return false;
		}
	}
	
}
